<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://"
            + request.getServerName() + ":" + request.getServerPort()
            + path + "/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
    <base href="<%=basePath%>">

    <title>My JSP 'login.jsp' starting page</title>

    <meta http-equiv="pragma" content="no-cache">
    <meta http-equiv="cache-control" content="no-cache">
    <meta http-equiv="expires" content="0">
    <meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
    <meta http-equiv="description" content="This is my page">
    <!--
        <link rel="stylesheet" type="text/css" href="styles.css">
        -->

</head>

<body>
<script type="text/javascript" src="/js/public/jquery-1.11.2.min.js"></script>

<script >
    $(

        function () {


            $("#foem").submit(function (event) {
                //window.location.href="downloadCourseFile";
//                $.get("downloadCourseFile",function(data,status){
//                    alert("数据：" + data + "\n状态：" + status);
//                });

//                if ($("#saveOneChapter").val() == "") {
//                    alert('请选择文件');
//                    return false;
//                }


                //alert(111)


                var formData = new FormData(this);
                //				loading1.show()
//			in
                $.ajax({
                    url: 'imStuExcelByClass',
                    type: 'post',
                    data: formData,
                    async: false,
                    cache: false,
                    contentType: false,
                    processData: false,
                    success: function (msg) {


                        alert(msg);
                    }


                });
                return false;
            });

        });
</script>
<a href="" id="zzz">testttt</a>
<a href="downloadCourseFile" >下载课件的</a>
<form id="foem"  method="post" class="login-form" enctype="multipart/form-data" >
    <div class="form-group">

        <input type="file" name="file" id="file">
        <input type="text" name="classId" id="classId" value="0">
        <input type="text" name="type" id="type" value="2">
        <!--
        <input type="text" name="chapterId" id="chapterId" value="311">
        类型：<input type="text" name="addTestMark" id="addTestMark">
        章节名：<input type="text" name="chapterName" id="chapterName">

        课件：<input type="file" name="courseware" id="courseware">
        视频：<input type="file" name="video" id="video">
        作业：<input type="file" name="homework" id="homework">
        备课材料：<input type="file" name="courseMaterial" id="courseMaterial">
        课程答案：<input type="file" name="courseAnswer" id="courseAnswer">
        实验手册：<input type="file" name="testDocName" id="testDocName">
        文件包：<input type="file" name="packageFile" id="packageFile">
        <input type="text" name="delHomework" id="delHomework" value="false">
        <input type="text" name="delVideo" id="delVideo" value="false">
        <input type="text" name="delMaterial" id="delMaterial" value="false">
        <input type="text" name="delAnswer" id="delAnswer" value="false">
    <input type="text" name="delTest" id="delTest" value="false">
        <input type="text" name="delCourseware" id="delCourseware" value="false">
        <input type="text" name="delPackageFile" id="delPackageFile" value="false">

-->

    </div>

    <button type="submit" class="btn">登录</button>
    <div class="clear"></div>

</form>
</body>
</html>
